Skip to content

Conversation

@oxtoacart
Copy link
Collaborator

OAuthCredentials can now be provided directly to the Client type.

Using OAuthConfig.HTTPClient() is now deprecated.

Updates tailscale/terraform-provider-tailscale#485

client.go Outdated
APIKey string
// OAuthCredentials specifies credentials for authenticating with OAuth. If provided,
// APIKey is ignored.
OAuthCredentials *OAuthCredentials
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Combining all of the OAuth credentials into a single type so that it's just a single configuration field on the Client is nice because it avoids confusion about which combinations of fields are required for what.

client.go Outdated
APIKey string
// Authentication specifies a mechanism for adding authentication to outgoing requests.
// If provided, APIKey is ignored.
Authentication Authentication
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is now pluggable. I'm using it for OAuth, we can also implement it for WIF, etc.

OAuth can now be provided directly to the Client type.

Using OAuthConfig.HTTPClient() is now deprecated.

Updates tailscale/terraform-provider-tailscale#485

Signed-off-by: Percy Wegmann <[email protected]>
@oxtoacart
Copy link
Collaborator Author

Closing in favor of #61

@oxtoacart oxtoacart closed this Oct 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant